package console;

/**
 * User: sachinh
 * Date: 25-Dec-2008
 * Time: 23:09:23
 */
public class Rect {
    public int left;
    public int top;
    public int right;
    public int bottom;

    public Rect(int left, int top, int right, int bottom) {
        this.left = left;
        this.top = top;
        this.right = right;
        this.bottom = bottom;
    }

    public int getHeight() {
        return bottom - top + 1;
    }

    public int getWidth() {
        return right - left + 1;
    }

    public String toString() {
        return left + "," + top + ":" + right + "," + bottom;
    }
}
